<<<<<<< HEAD
<!--
 * @Author: Xia_cc 978487464@qq.com
 * @Date: 2022-06-07 18:36:46
 * @LastEditors: Xia_cc 978487464@qq.com
 * @LastEditTime: 2022-06-10 15:37:01
 * @FilePath: \vue 小U到家\src\views\Mainjichushezhi.vue
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<!--  -->
<template>
  <div>
    <div class="textarea">
      用户协议 : &nbsp;&nbsp;
      <el-input
        type="textarea"
        :rows="10"
        placeholder="请输入内容"
        v-model="textarea"
        class="textInput"
        >{{ textarea }}</el-input
      >
      <el-button type="primary" class="baocunBut" @click="sheZhi()">保存</el-button>
    </div>
  </div>
</template>

<script>
export default {
  name: "Mainjichushezhi",
  //数据
  data() {
    return {
      textarea: "",
    };
  },
  //注册
  components: {},
  //方法
  methods: {
    sheZhi() {
      this.$axios({
        method: "post",
        url: "/xiaoucomeshome_war/admin/userAgree",
        params: {
          agree_desc: this.textarea,
        },
      })
        .then((res) => {
          // this.textarea = res.data.data.agree_desc;
        })
        .catch((err) => {
          console.log(err);
        });
    },
  },
  //挂载
  mounted() {},
};
</script>

<style lang="less" scoped>
.textarea {
  margin: 100px 50px;
  width: 500px;
  position: relative;

  .textInput {
    width: 70%;
    vertical-align: top;
  }

  .baocunBut {
    width: 100px;
    position: absolute;
    right: 50px;
    bottom: -100px;
  }
}
</style>
=======
<!--
 * @Author: Xia_cc 978487464@qq.com
 * @Date: 2022-06-07 18:36:46
 * @LastEditors: Xia_cc 978487464@qq.com
 * @LastEditTime: 2022-06-10 15:37:01
 * @FilePath: \vue 小U到家\src\views\Mainjichushezhi.vue
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<!--  -->
<template>
    <div>
        <div class="textarea">
            用户协议 : &nbsp;&nbsp;
            <el-input type="textarea" :rows="10" placeholder="请输入内容" v-model="textarea" 
                class="textInput">{{textarea}}</el-input>
            <el-button type="primary" class="baocunBut">保存</el-button>
        </div>
    </div>
</template>

<script>
export default {
    name: 'Mainjichushezhi',
    //数据
    data() {
        return {
            textarea: ''
        }
    },
    //注册
    components: {
    },
    //方法
    methods:{
        sheZhi(){
            this.$axios({
                method:"post",
                url:"/xiaoucomeshome_war/admin/userAgree",
            }).then((res)=>{
                this.textarea=res.data.data.agree_desc;
            }).catch((err)=>{
                console.log(err);
            });
        }
    },
    //挂载
    mounted(){
        this.sheZhi();
    },
}
</script>

<style lang='less' scoped>
.textarea {
    margin: 100px 50px;
    width: 500px;
    position: relative;

    .textInput {
        width: 70%;
        vertical-align: top;
    }

    .baocunBut{
        width: 100px;
        position: absolute;
        right: 50px ;
        bottom:-100px;
    }
}
</style>
>>>>>>> ae27e4fe2d4f939d0b0ee2bfa506b9e3269c53cb
